<table class="batch-detail">
    <tr>
        <th>Discount(Amt)</th>
        <th>Discount%</th>
        <th>Valid Till</th>
    </tr>
     <?php foreach ($classEarlyDiscount as $classEarlyValue) { ?>
    <tr>
        <td><?php echo ($classEarlyValue->discount_price == '') ? 'NULL' : $classEarlyValue->discount_price; ?></td>
        <td><?php echo ($classEarlyValue->in_percentage == '') ? 'NULL' : $classEarlyValue->in_percentage; ?></td>
        <td><?php echo date("Y:m:d", strtotime($classEarlyValue->valid_to)); ?></td>
    </tr>
     <?php } ?>
</table>